package com.xjoyt.pay.share.controllers;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.xjoyt.pay.controllers.AbstractController;
import com.xjoyt.pay.dto.ExecuteResult;
import com.xjoyt.pay.share.interfaces.FileObejctContract;
import com.xjoyt.pay.share.po.FileObejct;
import com.xjoyt.pay.share.services.FileObejctService;
import com.xjoyt.pay.share.vo.FileObjecResult;
import com.xjoyt.pay.share.vo.FileObjectParam;

@RestController
@RequestMapping("fileObejct")
public class FileObejctController extends AbstractController implements FileObejctContract {

	@Autowired
	private FileObejctService service;

	@Override
	public ExecuteResult<FileObejct> save(@RequestBody FileObejct param) {
		return service.save(param);
	}

	@Override
	public ExecuteResult<?> saveAllUrl(@RequestBody List<FileObejct> param) {
		return service.saveAllUrl(param);
	}
	
	@Override
	public List<FileObjecResult> findAllByKeysAndProperties(@RequestBody FileObjectParam param){
		return service.findAllByKeysAndProperties(param);
	}
	
	
}
